package com.xhj.myframe.myspring.zhouyu;

import org.springframework.context.annotation.AnnotationConfigApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;
/**
 * -
 *
 * @author 见见 pure_xhj@163.com @Date 2021-08-28 @Time 18:11
 */
public class SpringApplication {
  public static void main(String[] args) {
    ClassPathXmlApplicationContext classPathXmlApplicationContext =
        new ClassPathXmlApplicationContext("zhouyu-spring.xml");
    AnnotationConfigApplicationContext applicationContext =
        new AnnotationConfigApplicationContext(AppConfig.class);

    UserService userService =
        classPathXmlApplicationContext.getBean("userService", UserService.class);
    userService.test();
  }
}
